<?php
namespace Home\Controller;
use Think\Controller;
class ChearkController extends Controller {
        function _initialize(){
            $id = session('id');
            if(empty($id)){
                session(null);
                header("location:http://rty.tunnel.qydev.com/weixi/index.php/Home/register/login");
//                header('HTTP/1.1 403');
//                header('Content-Type:text/html;charset=UTF-8');
//                echo '<script>alert("请登录！在来哦^_^"); location="'.U('Index/index').'";</script>';
                return;
            }

            $userid = $this->nameId = session('id');
        }
}